﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;

namespace LEEAAttendanceControl.Views
{
    public partial class TodayAbsence : ChildWindow
    {
        public TodayAbsence()
        {
            InitializeComponent();

            EmployeesDataSource.QueryParameters.Clear();

            Parameter comParameter = new Parameter();

            comParameter.ParameterName = "companyID";
            comParameter.Value = ((App)Application.Current).CompanyID == null
                ? 0 : ((App)Application.Current).CompanyID.Value;

            EmployeesDataSource.QueryParameters.Add(comParameter);

            Parameter dayParameter = new Parameter();

            dayParameter.ParameterName = "day";
            dayParameter.Value = DateTime.Now;

            EmployeesDataSource.QueryParameters.Add(dayParameter);
        }

        private void OKButton_Click(object sender, RoutedEventArgs e)
        {
            this.DialogResult = true;
        }
    }
}

